﻿namespace Deppton.Model
{
    using System.Collections.Generic;

    public class SurveyDefinition
    {
        public SurveyDefinition()
        {
            this.Questions = new NamedList<Question>(q => q.Id);
            this.ResultDefinitions = new List<SurveyResultDefinition>();
            this.RulesetDefinitions = new NamedList<RulesetDefinition>(r => r.Id);
        }

        public string Id
        {
            get;
            set;
        }

        public string Description
        {
            get;
            set;
        }

        public NamedList<Question> Questions
        {
            get;
            set;
        }

        public List<SurveyResultDefinition> ResultDefinitions
        {
            get;
            private set;
        }

        public NamedList<RulesetDefinition> RulesetDefinitions
        {
            get;
            private set;
        }

        public string CompletedConditionRulesetId
        {
            get;
            set;
        }
    }
}
